package com.bs.product.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.Version;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

//存放所有实体类的公共属性
@Data
public class BaseEntity {
    //插入时间 指定在新增数据是填充
    @ApiModelProperty("创建时间")
    @TableField(fill = FieldFill.INSERT)
    private String createTime;
    @ApiModelProperty("修改时间")
    @TableField(fill = FieldFill.UPDATE)
    private String updateTime;
    @ApiModelProperty("版本")
    @Version
    private Integer version;
    @ApiModelProperty("删除标记位0代表未删除，1带表以删除")
    @TableLogic(delval = "1",value = "0")
    private Integer deleted;
}
